package com.hubujun.driverlicense.util;

import android.content.Context;
import android.widget.Toast;

import java.util.HashSet;

public class ShowUtils {

	public static final int GLOBAL_R_CODE_PARAMETER_ERROR_BUSY = 0xFF;

	public static final int GLOBAL_R_CODE_PARAMETER_ERROR_UNKNOWN = 0xFE;

	public static final int GLOBAL_R_CODE_PARAMETER_ERROR_INTERNAL = 0xFD;

	public static final int GLOBAL_R_CODE_PARAMETER_ERROR_SESSION_TIMEOUT = 0xFC;

	public static final int GLOBAL_R_CODE_PARAMETER_ERROR_INVALID_AUTH = 0xFB;

	public static final int GLOBAL_R_CODE_PARAMETER_ERROR_INVALID_PERMISSIONS = 0xFA;

	public static final int GLOBAL_R_CODE_PARAMETER_ERROR_PARAMETER = 0xF9;

	public static final int GLOBAL_R_CODE_PARAMETER_ERROR_RULE_BREAK = 0xF8;

	public static final int GLOBAL_R_CODE_PARAMETER_ERROR_REVIEW = 0xF7;

	public static final int GLOBAL_RCODE_PARAMTER_ERROR_START = GLOBAL_R_CODE_PARAMETER_ERROR_REVIEW;

	public static HashSet<Integer> mShowedToastScenes = new HashSet<Integer>();

	private ShowUtils() {
	}

	public static void toastMsg(Context context, String s) {
		if (s != null && s.length() > 0) {
			ToastUtils.showToast(context, s, Toast.LENGTH_LONG);
		}
	}

	public static void toastShortMsg(Context context, String s) {
		if (s != null && s.length() > 0) {
			ToastUtils.showToast(context, s, Toast.LENGTH_SHORT);
		}
	}

}
